<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<html lang="zh-cn" xml:lang="zh-cn">
 <head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="DC.Type" content="topic">
  <meta name="DC.Title" content="步骤5：（可选）配置日志备份">
  <meta name="product" content="">
  <meta name="DC.Relation" scheme="URI" content="zh-cn_topic_0000001839188597.html">
  <meta name="prodname" content="">
  <meta name="version" content="">
  <meta name="brand" content="30-OceanProtect 备份一体机 1.5.0-1.6.0 帮助中心">
  <meta name="DC.Publisher" content="20240320">
  <meta name="DC.Format" content="XHTML">
  <meta name="DC.Identifier" content="ZH-CN_TOPIC_0000001792389536">
  <meta name="DC.Language" content="zh-cn">
  <link rel="stylesheet" type="text/css" href="public_sys-resources/commonltr.css">
  <title>步骤5：（可选）配置日志备份</title>
 </head>
 <body style="clear:both; padding-left:10px; padding-top:5px; padding-right:5px; padding-bottom:5px">
  <a name="ZH-CN_TOPIC_0000001792389536"></a><a name="ZH-CN_TOPIC_0000001792389536"></a>
  <h1 class="topictitle1">步骤5：（可选）配置日志备份</h1>
  <div>
   <p>如果在<a href="zh-cn_topic_0000001839268545.html">步骤4：创建备份SLA</a>中配置了日志备份，请参考本节在SAP HANA数据库开启日志备份，日志备份才能生效。非该场景请忽略本节。</p>
   <div class="section">
    <h4 class="sectiontitle">背景信息</h4>
    <p><span>本产品</span>对SAP HANA数据库的日志备份依赖SAP HANA自身的日志备份能力。SAP HANA备份日志后，<span>本产品</span>将其备份至备份存储。</p>
   </div>
   <div class="section">
    <h4 class="sectiontitle">操作步骤</h4>
    <ol>
     <li><span>登录系统数据库。</span><p></p>
      <ol type="a">
       <li>使用PuTTY，登录SAP HANA数据库主机。</li>
       <li>执行以下命令，切换到系统用户。<pre class="screen">su - <em>systemi</em><em>d</em>adm</pre> <p>如：</p> <pre class="screen">su - k00adm</pre></li>
       <li>执行以下命令，登录系统数据库。<pre class="screen">hdbsql -i <em>实例id</em> -n <em>系统数据库主节点的hostname</em>:<em>系统数据库的SQL Port</em> -d SYSTEMDB -u <em>系统数据库用户名</em> -p<em> 系统数据库密码</em></pre> <p>如：</p> <pre class="screen">hdbsql -i 00 -n localhost:30013 -d SYSTEMDB -u SYSTEM -p xxxxxxx</pre></li>
      </ol> <p></p></li>
    </ol>
    <ol start="2">
     <li><span>开启并配置日志备份功能。</span><p></p>
      <ol type="a">
       <li>执行以下命令开启SAP HANA数据库日志备份。<pre class="screen">alter system alter configuration ('global.ini', 'SYSTEM') set ('persistence', 'enable_auto_log_backup') = 'yes' with reconfigure;</pre></li>
       <li>执行以下命令设置日志备份副本的存放目录。
        <div class="p">
         请确保日志备份副本目录可用空间大于所有日志备份副本将占用的空间。
         <pre class="screen">alter system alter configuration ('global.ini', 'SYSTEM') set ('persistence', 'basepath_logbackup') = '<em>日志副本存放目录</em>'  with reconfigure;</pre>
        </div></li>
       <li>执行以下命令设置日志备份的频率，即间隔多久备份一次。<pre class="screen">alter system alter configuration ('global.ini', 'SYSTEM') set ('persistence', 'log_backup_timeout_s') = '<em>日志备份频率</em><em>（单位为秒）</em>' with reconfigure;</pre> <p>建议该时间间隔的取值在<a href="zh-cn_topic_0000001839268545.html#ZH-CN_TOPIC_0000001839268545__table2663151516335">表1</a>中设置的日志备份时间间隔的50%~100%之间。当备份策略中设置的日志备份时间间隔为60分钟，此步骤建议配置的时间间隔取值范围为30分钟~60分钟。</p></li>
      </ol> <p></p></li>
    </ol>
   </div>
   <p></p>
  </div>
  <div>
   <div class="familylinks">
    <div class="parentlink">
     <strong>父主题：</strong> <a href="zh-cn_topic_0000001839188597.html">备份SAP HANA数据库</a>
    </div>
   </div>
  </div>
 </body>
</html>